/**
 * Copyright (C) 2021 - 2031 O-Cubes Co., Ltd.
 */

/****************************************************************
 *  @file    config_p1.h
 *  @brief   config definition header file.
 *  @version v1.0
 *  @date    03. Apr. 2023
 ****************************************************************/

#ifndef __CONFIG_P1_H__  /* prevent circular inclusions */
#define __CONFIG_P1_H__  /* by using protection macros */


#ifdef __cplusplus
extern "C" {
#endif

#define DMEM_BASE                0x00200000
#define DMEM_SIZE                0x10000
#define IMEM_BASE                0x00400000
#define IMEM_SIZE                0x20000
#define MIN_HEAP_SIZE            0x200
#define SDK_IMG_HDR_LEN          0x40

/* Used in ld scripts */
#if 1
#define SPIFLASH_XIP_EN          1
#define FLASH_BASE               (CONFIG_SDK_PART1_FLASH_BASE + SDK_IMG_HDR_LEN)
#define FLASH_SIZE               CONFIG_SDK_PARTITION_SIZE
#else
#define FLASH_BASE               IMEM_BASE
#define FLASH_SIZE               IMEM_SIZE
#endif

#ifdef __cplusplus
}
#endif

#endif /*end of __CONFIG_P1_H__ */
